//
//  AllCarTableViewCell.m
//  Car
//
//  Created by lanou on 15/9/17.
//  Copyright (c) 2015年 朱鸿儒. All rights reserved.
//

#import "AllCarTableViewCell.h"

@implementation AllCarTableViewCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    if (self) {
        self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
        self.selectionStyle = 0;
        self.image = [[UIImageView alloc]initWithFrame:CGRectMake(10, 0, 60, 40)];
        [self addSubview:self.image];
        
        self.lable = [[UILabel alloc]initWithFrame:CGRectMake(70, 0, kWidth - 70, 40)];
        self.lable.textAlignment = 0;
        [self addSubview:self.lable];
        UIView *line = [[UIView alloc]initWithFrame:CGRectMake(10, 49, kWidth - 10, 0.5)];
        line.backgroundColor = [UIColor lightGrayColor];
        [self addSubview:line];
        
    }
    return self;
}
- (void)setValueWithModel:(BrandModel *)model{
    [self.image sd_setImageWithURL:[NSURL URLWithString:model.imgurl]];
    self.lable.text = model.name;
}
- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
